package com.inspur.dgov.policy.feign;

import com.alibaba.fastjson.JSONObject;
import com.inspur.dgov.common.tool.api.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * Es接口
 *
 * @Author chiyupei
 * @Date 20/3/23 下午3:34
 * @Version 1.0
 * @Description Es接口
 */
@FeignClient(value = "epolicy-cloud-persist")
public interface IEsPolicyFeign {

    String API_PREFIX = "/policy";

    @PostMapping(API_PREFIX + "/insert")
    R insert(@RequestBody JSONObject data);

    @PostMapping(API_PREFIX + "/update/info")
    R update(@RequestBody JSONObject data);

    @PostMapping(API_PREFIX + "/update/bulk/info")
    R updateBatch(@RequestBody JSONObject data);

    @PostMapping(API_PREFIX + "/delete")
    R delete(@RequestBody JSONObject data);
}
